package com.xxg.renrencommon.exception.exceptionenum;

/**
 * 类说明
 *
 * @author szj
 * @date 2021/11/26
 */
public enum ShoppingCartExceptionCodeCodeEnum implements ReturnExceptionCode {

    /**
     * 商品不存在
     */
    SKU_NOT_EXIST("商品不存在", 2100)
    ;
    /**
     * 枚举的名称
     */
    private final String name;
    /**
     * 枚举的代码
     */
    private final int code;

    ShoppingCartExceptionCodeCodeEnum(String name, int code) {
        this.name = name;
        this.code = code;
    }

    @Override
    public String getName() {
        return name;
    }

    @Override
    public int getCode() {
        return code;
    }

    @Override
    public String toString() {
        return this.code + "_" + this.name;
    }
}
